package reflectDemo;

public class Student {
    private   String name = "nan";
    public  int age = 19;
    public Student(){
        System.out.println("无题");
    }
    public Student(String name,int age){
        this.name = name;
        this.age = age;
        System.out.println("有东西的构造方法");
    }
    private  void study(){
        System.out.println("i like studying in library");
    }
    public void play(){
        System.out.println("i like playing mobile phone");
    }
    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", age=" + age +
                '}';
    }
}
